package com.linkage.lcims.base.po.business;

import java.io.Serializable;
import org.apache.commons.lang.builder.EqualsBuilder;
import org.apache.commons.lang.builder.HashCodeBuilder;
import org.apache.commons.lang.builder.ToStringBuilder;


/** @author Hibernate CodeGenerator */
@SuppressWarnings("serial")
public class BdGroupAuthorPK implements Serializable {

    /** identifier field */
    private Integer groupid;

    /** identifier field */
    private Integer recordid;

    /** identifier field */
    private Integer attrid;

    /** full constructor */
    public BdGroupAuthorPK(Integer groupid, Integer recordid, Integer attrid) {
        this.groupid = groupid;
        this.recordid = recordid;
        this.attrid = attrid;
    }

    /** default constructor */
    public BdGroupAuthorPK() {
    }

    /** 
     *                @hibernate.property
     *                 column="groupid"
     *                 length="10"
     *             
     */
    public Integer getGroupid() {
        return this.groupid;
    }

    public void setGroupid(Integer groupid) {
        this.groupid = groupid;
    }

    /** 
     *                @hibernate.property
     *                 column="recordid"
     *                 length="10"
     *             
     */
    public Integer getRecordid() {
        return this.recordid;
    }

    public void setRecordid(Integer recordid) {
        this.recordid = recordid;
    }

    /** 
     *                @hibernate.property
     *                 column="attrid"
     *                 length="10"
     *             
     */
    public Integer getAttrid() {
        return this.attrid;
    }

    public void setAttrid(Integer attrid) {
        this.attrid = attrid;
    }

    public String toString() {
        return new ToStringBuilder(this)
            .append("groupid", getGroupid())
            .append("recordid", getRecordid())
            .append("attrid", getAttrid())
            .toString();
    }

    public boolean equals(Object other) {
        if ( (this == other ) ) return true;
        if ( !(other instanceof BdGroupAuthorPK) ) return false;
        BdGroupAuthorPK castOther = (BdGroupAuthorPK) other;
        return new EqualsBuilder()
            .append(this.getGroupid(), castOther.getGroupid())
            .append(this.getRecordid(), castOther.getRecordid())
            .append(this.getAttrid(), castOther.getAttrid())
            .isEquals();
    }

    public int hashCode() {
        return new HashCodeBuilder()
            .append(getGroupid())
            .append(getRecordid())
            .append(getAttrid())
            .toHashCode();
    }

}
